﻿using System;
using System.Collections.Generic;
using System.Text;
using System.Collections;

namespace CoolCode.Caching
{
    public class HashCacheStrategy : ICacheStrategy
    {
        private Hashtable objectStore;

        public HashCacheStrategy()
        {
            objectStore = new Hashtable();
        }

        public void Insert(string key, object obj)
        {
            objectStore.Add(key, obj);
        }

        public object Get(string key)
        {
            return objectStore[key];
        }

        public void Remove(string key)
        {
            objectStore.Remove(key);
        }
    }
}
